package com.fs.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.fs.pojo.UserToken;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

/**
 * 管理员登录token表
 */
@Mapper
public interface UserTokenMapper extends BaseMapper<UserToken> {

    @Select("select * from user_token where user_id=#{userId}")
    UserToken findByUserId(Integer userId);

    @Select("select * from user_token where token=#{accessToken}")
    UserToken findByToken(String accessToken);
}
